<%@ taglib prefix="s" uri="/struts-tags"%>
<%@ taglib prefix="ajax" uri="javawebparts/ajaxparts/taglib" %>

<%@ page contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>


<table width="100%" border="0" cellspacing="0" cellpadding="0">
        <tr>
          <td height="103" valign="top" class="top-bg"><div style="margin:0px 20px 0px 29px">
              <table width="100%" border="0" cellspacing="0" cellpadding="0">
                <tr>
                  <td width="61%" height="103" align="${alignleft}" valign="top"><div style="margin:30px 0px 0px 0px"><img src="<%=request.getContextPath()%>/images/top/logo.jpg" alt="PrintPackPaper Logo" width="307" height="52" /></div></td>
                  <td width="39%" align="${alignright}" valign="top"><table width="100%" border="0" cellspacing="0" cellpadding="0">
                      <tr>
                        <td align="${alignright}">
                        	<div class="home-navi-separator" style="margin:16px 0px 0px 0px"><table width="100%" border="0" cellspacing="0" cellpadding="0">
  								<tr>
   	 								<td width="84%" align="${alignright}" valign="top">
										<s:if test="#session.user == null">
											<a href="<%=request.getContextPath()%>/login.htm" class="home-navi-link-bold"><s:text name="lable.login" /></a> |
											<a href="<%=request.getContextPath()%>/registrationForm.htm" class="home-navi-link-bold"><s:text name="link.register" /></a> |
										</s:if>
										<s:else>
											<a href="<%=request.getContextPath()%>/logout.htm" class="home-navi-link-bold"><s:text name="link.logout" /></a> |
										</s:else>
											<a href="<%= request.getContextPath() %>/help/help.htm" class="home-navi-link"><s:text name="link.help" /></a> |
											<a href="<%= request.getContextPath() %>/smartSearch.htm" class="home-navi-link"><s:text name="smartsearch.title" /> </a> |
                        			</td>
                        			<td align="${alignright}" width="16%">
				                        <div class="language" id=chromemenu3>
				          						<ul>
				           							<li><a href="#" rel=dropmenu8><s:text name="lable.language" /></a></li>
				          						</ul>
			        					</div>
			        					<div class="dropmenudiv-language" id=dropmenu8>
											<s:iterator value="#attr.languages" var="language">
												<a href="#" style="cursor: pointer;" onclick="refresh('<s:property value="%{languageCode}" />')"><s:property value="%{#language.languageName}" /></a>
											</s:iterator>
										</div>
										<script type="text/javascript">
											function refresh(locale){
												var currenturl = unescape(window.location.href);
												if(currenturl.indexOf(".htm?")>0){
													var li =currenturl.indexOf("?request_locale=");
													if(li>0){
													currenturl = escape(window.location.pathname);
													window.location.replace(currenturl + "?request_locale="+locale);
													}else{
													var fi =currenturl.indexOf("&request_locale=");
													var len=currenturl.length;
													if(fi>0){
													var first = currenturl.substring(0,fi);
													var second=  currenturl.substring((fi+18),len);
													currenturl = first+second;
													}
													window.location.replace(currenturl + "&request_locale="+locale);
													}
												}else{
													window.location.replace(currenturl + "?request_locale="+locale);
												}
											}
										</script>
									</td>
  								</tr>
							</table>
							</div>
						</td>
                      </tr>
                      <tr>
                        <td align="${alignright}" colspan="2">
                        <s:if test="#session.user != null">
                        	<div class="welcome-text" style="margin:50px 0px 0px 0px"><s:text name="lable.welcome" /> <span class="visitor-text"><s:property value="#session.user.userId" /></span>,</div>
                        </s:if>
                        </td>
                      </tr>
                    </table></td>
                </tr>
              </table>
            </div></td>
        </tr>
        <tr>
          <!--navigation start -->
          <td height="30" align="center" valign="top" class="navi-bg">
          <div style="margin: 0px 0px 0px 0px">
				<%@include file="front-user-menu.jsp"%>
			</div>
          </td>
          <!--navigation end -->
        </tr>
        <tr>
          <!--search start -->
          <td height="67" valign="top" class="search-bg"><div style="margin:8px 20px 8px 20px">
              <form action="browseItems.htm">
              <table width="100%" border="0" cellspacing="0" cellpadding="0">
                <tr>
                  <td width="25%" align="center"><div style="margin:0px 7px 0px 0px">
                      <select name="ItemType" class="search-textmenu">
                        <option selected="selected">Please Select One</option>
                        <option>All items for sale (157)</option>
                        <option>Advertisements (180)</option>
                        <option>Company profiles (180)</option>
                        <option>Fixed price (180)</option>
                        <option>Items Wanted (180)</option>
                        <option>Reverse auction (180)</option>
                        <option>Shop (180)</option>
                        <option>Straight auction (180)</option>
                      </select><ajax:event ajaxRef="SearchAjax/showCatagoriesforsearch" />
                    </div></td>
                  <td width="25%" align="center"><div style="margin:0px 7px 0px 0px">
                      <select name="categories" class="search-textmenu">
                        <option selected="selected">Select Category</option>
                      </select>
                    </div></td>
                  <td width="25%" align="center"><div style="margin:0px 7px 0px 0px">
                      <select name="select4" class="search-textmenu">
                        <option>All Locations (180)</option>
                      </select>
                    </div></td>
                  <td width="25%" align="center"><div style="margin:0px 0px 0px 0px">
                      <select name="select5" class="search-textmenu">
                        <option>All Languages (180)</option>
                      </select>
                    </div></td>
                </tr>
              </table>
              <div style="margin:6px 0px 0px 0px">
                <table width="100%" border="0" cellpadding="0" cellspacing="0">
                  <tr>
                    <td width="141" align="${alignleft}" valign="middle"><div class="search-text" style="margin:0px 8px 0px 0px"><s:text name="lable.searchbykeyword" /></div></td>
                    <td align="${alignleft}" valign="middle"><div class="search-text" style="margin:0px 14px 0px 0px">
                        <input name="textfield" type="text" class="search-textfield" />
                    </div></td>
                    <td width="190" align="${alignright}" valign="middle"><div style="margin:0px 7px 0px 0px">
                        <select name="select" class="search-textmenu">
                          <option value="1">Search in titles</option>
                          <option>In Titles &amp; Text</option>
                        </select>
                    </div></td>
                    <td width="150" align="${alignright}" valign="middle"><table border="0" align="${alignright}" cellpadding="0" cellspacing="0">
                        <tr>
                           <td><div style="margin:0px 14px 0px 0px">
                              <table border="0" cellspacing="0" cellpadding="0">
			                    <tr>
			                      <td class="btn-grey-left1"></td>
			                      <td class="btn-grey-middle1">
			                       <s:submit value="%{getText('smartsearch.button.find')}"  theme="simple" cssClass="submit-btn-common" disabled="true"/>
			             	    </td>
			                     <td class="btn-grey-right1"></td>
			                    </tr>
			                  </table>
                            </div></td>
                          <td><table border="0" cellspacing="0" cellpadding="0">
																<tr>
																		<td class="btn-grey-left1"></td>
																	<td class="btn-grey-middle1 ">
																		<s:reset value="%{getText('button.reset')}" theme="simple"
																			cssClass="submit-btn-common" />
																	</td>
																	<td class="btn-grey-right1"></td>
																</tr>
															</table>
							</td>
                        </tr>
                    </table></td>
                  </tr>
                </table>
              </div>
              </form>
            </div></td>
          <!--search end -->
        </tr>
        <ajax:enable/>
      </table>
